package com.fqgj.sentry.policy.dao;

import com.fqgj.common.base.BaseMapper;
import com.fqgj.sentry.policy.entity.PcRuleColumnEntity;

import java.util.List;

/**
 * User: liupengpeng
 * Date: 2017-07-25
 * Time: 15:46:14.846
 */

public interface PcRuleColumnDao extends BaseMapper<PcRuleColumnEntity> {
    /**
     * 根据字段ID 查询
     *
     * @param columnId
     * @return
     */
    List<PcRuleColumnEntity> selectByColumnId(Long columnId);

    /**
     * 根据规则id 删除
     *
     * @param ruleId
     * @return
     */
    Integer deleteByRuleId(Long ruleId);

    /**
     *
     * @param ruleIds
     * @return
     */
    void deleteByRuleIds(List<Long> ruleIds);

    /**
     * 根据规则id 删除
     *
     * @param ruleId
     * @return
     */
    Integer updateDeleteByRuleId(Long ruleId);

    /**
     * 根据规则 查询
     *
     * @param ruleId
     * @return
     */
    List<PcRuleColumnEntity> findByRuleId(Long ruleId);

    List<PcRuleColumnEntity> findByRuleIds(List<Long> ruleIds);


}